package com.dinpay.plugin.d;

import android.content.res.Resources;
import android.graphics.Bitmap;
import android.graphics.Rect;
import android.graphics.drawable.BitmapDrawable;
import android.graphics.drawable.Drawable;
import android.graphics.drawable.NinePatchDrawable;
import android.text.TextUtils;

public final class i
{
  public static Drawable a(Resources paramResources, Class paramClass, String paramString)
  {
    if (TextUtils.isEmpty(paramString))
      return null;
    try
    {
      Bitmap localBitmap = j.a(paramClass.getResourceAsStream(paramString));
      if (localBitmap == null)
        return null;
      if (localBitmap.getNinePatchChunk() == null)
        return new BitmapDrawable(localBitmap);
      Rect localRect = new Rect();
      j.a(localBitmap.getNinePatchChunk(), localRect);
      NinePatchDrawable localNinePatchDrawable = new NinePatchDrawable(paramResources, localBitmap, localBitmap.getNinePatchChunk(), localRect, null);
      return localNinePatchDrawable;
    }
    catch (Exception localException)
    {
    }
    return null;
  }

  // ERROR //
  public static Drawable a(Class paramClass, String paramString)
  {
    // Byte code:
    //   0: aload_1
    //   1: invokestatic 18	android/text/TextUtils:isEmpty	(Ljava/lang/CharSequence;)Z
    //   4: istore_2
    //   5: aconst_null
    //   6: astore_3
    //   7: iload_2
    //   8: ifeq +5 -> 13
    //   11: aload_3
    //   12: areturn
    //   13: aload_1
    //   14: ldc 56
    //   16: invokevirtual 62	java/lang/String:split	(Ljava/lang/String;)[Ljava/lang/String;
    //   19: astore 4
    //   21: aconst_null
    //   22: astore_3
    //   23: aload 4
    //   25: ifnull -14 -> 11
    //   28: aload 4
    //   30: arraylength
    //   31: istore 5
    //   33: aconst_null
    //   34: astore_3
    //   35: iload 5
    //   37: ifeq -26 -> 11
    //   40: aload_0
    //   41: aload_1
    //   42: invokevirtual 24	java/lang/Class:getResourceAsStream	(Ljava/lang/String;)Ljava/io/InputStream;
    //   45: astore 12
    //   47: aload 12
    //   49: astore 7
    //   51: aload 7
    //   53: aload 4
    //   55: iconst_m1
    //   56: aload 4
    //   58: arraylength
    //   59: iadd
    //   60: aaload
    //   61: invokestatic 68	android/graphics/drawable/Drawable:createFromStream	(Ljava/io/InputStream;Ljava/lang/String;)Landroid/graphics/drawable/Drawable;
    //   64: astore 14
    //   66: aload 14
    //   68: astore_3
    //   69: aload 7
    //   71: ifnull -60 -> 11
    //   74: aload 7
    //   76: invokevirtual 73	java/io/InputStream:close	()V
    //   79: aload_3
    //   80: areturn
    //   81: astore 15
    //   83: aload 15
    //   85: invokevirtual 76	java/io/IOException:printStackTrace	()V
    //   88: aload_3
    //   89: areturn
    //   90: astore 10
    //   92: aconst_null
    //   93: astore 7
    //   95: aconst_null
    //   96: astore_3
    //   97: aload 7
    //   99: ifnull -88 -> 11
    //   102: aload 7
    //   104: invokevirtual 73	java/io/InputStream:close	()V
    //   107: aconst_null
    //   108: areturn
    //   109: astore 11
    //   111: aload 11
    //   113: invokevirtual 76	java/io/IOException:printStackTrace	()V
    //   116: aconst_null
    //   117: areturn
    //   118: astore 6
    //   120: aconst_null
    //   121: astore 7
    //   123: aload 6
    //   125: astore 8
    //   127: aload 7
    //   129: ifnull +8 -> 137
    //   132: aload 7
    //   134: invokevirtual 73	java/io/InputStream:close	()V
    //   137: aload 8
    //   139: athrow
    //   140: astore 9
    //   142: aload 9
    //   144: invokevirtual 76	java/io/IOException:printStackTrace	()V
    //   147: goto -10 -> 137
    //   150: astore 8
    //   152: goto -25 -> 127
    //   155: astore 13
    //   157: goto -62 -> 95
    //
    // Exception table:
    //   from	to	target	type
    //   74	79	81	java/io/IOException
    //   40	47	90	java/lang/Exception
    //   102	107	109	java/io/IOException
    //   40	47	118	finally
    //   132	137	140	java/io/IOException
    //   51	66	150	finally
    //   51	66	155	java/lang/Exception
  }
}

/* Location:           C:\Users\user\Desktop\dd28_pcdd720\classes_dex2jar.jar
 * Qualified Name:     com.dinpay.plugin.d.i
 * JD-Core Version:    0.6.2
 */